package IC.Semantics.symbols;

import IC.AST.Field;
import IC.Semantics.SemanticError;
import IC.Semantics.types.AllMightyType;
import IC.Semantics.types.TypeTable;

public class FieldSymbol extends SemanticSymbol{

	/**
	 * standard constructor
	 * @param field
	 * @throws SemanticError
	 */
	public FieldSymbol(Field field) {
		super(field.getName(), field.getType().getLine(), TypeTable.getType(field.getType()), SemanticKind.FIELD);
	}
	
	/**
	 * constructor for forward referencing
	 * @param field
	 * @param fref
	 * @throws SemanticError
	 */
	public FieldSymbol(String name) {
		super(name, 0, new AllMightyType(), SemanticKind.FIELD, true);
	}

}
